package com.entity;


import java.text.SimpleDateFormat;
import java.util.Date;

public class User {
	private String uid;
	private String username;
	private String realname;
	private String password;
	private String gender;
	private String identityCode;
	private String email;
	private String mobile;
	private String address;
	private String role;
	private int state;
	private Date birthday;
	private String ubirthday;
	private Date regdate;
	private String uregdate;
	
	
	
	
	
	
	public User() {
		super();
		// TODO Auto-generated constructor stub
	}




	public User(String uid, String username, String realname, String password, String gender, String identityCode,
			String email, String mobile, String address, String role, int state, Date birthday, Date regdate) {
		super();
		this.uid = uid;
		this.username = username;
		this.realname = realname;
		this.password = password;
		this.gender = gender;
		this.identityCode = identityCode;
		this.email = email;
		this.mobile = mobile;
		this.address = address;
		this.role = role;
		this.state = state;
		this.birthday = birthday;
		this.regdate = regdate;
	}




	public User(String uid, String username, String realname, String password, String gender, String identityCode,
			String email, String mobile, String address, String role, int state, Date birthday) {
		super();
		this.uid = uid;
		this.username = username;
		this.realname = realname;
		this.password = password;
		this.gender = gender;
		this.identityCode = identityCode;
		this.email = email;
		this.mobile = mobile;
		this.address = address;
		this.role = role;
		this.state = state;
		this.birthday = birthday;
	}




	public User(String uid, String username, String realname, String password,
			String gender, String identityCode, String email, String mobile,
			String address, String role) {
		super();
		this.uid = uid;
		this.username = username;
		this.realname = realname;
		this.password = password;
		this.gender = gender;
		this.identityCode = identityCode;
		this.email = email;
		this.mobile = mobile;
		this.address = address;
		this.role = role;
	}


	public User(String uid, String username, String realname, String password,
			String gender, String identityCode, String mobile, String address,
			String role, int state, Date birthday, Date regdate) {
		super();
		this.uid = uid;
		this.username = username;
		this.realname = realname;
		this.password = password;
		this.gender = gender;
		this.identityCode = identityCode;
		this.mobile = mobile;
		this.address = address;
		this.role = role;
		this.state = state;
		this.birthday = birthday;
		this.regdate = regdate;
	}


	public String getRealname() {
		return realname;
	}


	public void setRealname(String realname) {
		this.realname = realname;
	}


	public String getPassword() {
		return password;
	}


	public void setPassword(String password) {
		this.password = password;
	}


	public String getGender() {
		return gender;
	}


	public void setGender(String gender) {
		this.gender = gender;
	}


	public String getIdentityCode() {
		return identityCode;
	}


	public void setIdentityCode(String identityCode) {
		this.identityCode = identityCode;
	}


	public String getMobile() {
		return mobile;
	}


	public void setMobile(String mobile) {
		this.mobile = mobile;
	}


	public String getAddress() {
		return address;
	}


	public void setAddress(String address) {
		this.address = address;
	}


	public String getRole() {
		return role;
	}


	public void setRole(String role) {
		this.role = role;
	}


	public int getState() {
		return state;
	}


	public void setState(int state) {
		this.state = state;
	}



	public String getUid() {
		return uid;
	}


	public void setUid(String uid) {
		this.uid = uid;
	}


	public String getUsername() {
		return username;
	}


	public void setUsername(String username) {
		this.username = username;
	}


	public String getUbirthday() {
		SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
		if(this.birthday!=null){
			return sdf.format(this.birthday);
		}
		return "";
	}

	public String getUregdate() {
		SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
		if(this.regdate!=null){
			return sdf.format(this.regdate);
		}
		return "";
	}
	
	public Date getBirthday() {
		return birthday;
	}


	public void setBirthday(Date birthday) {
		this.birthday = birthday;
	}


	public Date getRegdate() {
		return regdate;
	}

	public void setRegdate(Date regdate) {
		this.regdate = regdate;
	}


	public String getEmail() {
		return email;
	}


	public void setEmail(String email) {
		this.email = email;
	}




	@Override
	public String toString() {
		return "User [uid=" + uid + ", username=" + username + ", realname=" + realname + ", password=" + password
				+ ", gender=" + gender + ", identityCode=" + identityCode + ", email=" + email + ", mobile=" + mobile
				+ ", address=" + address + ", role=" + role + ", state=" + state + ", birthday=" + birthday
				+ ", ubirthday=" + ubirthday + ", regdate=" + regdate + ", uregdate=" + uregdate + "]";
	}
	
	
}
